import VueRouter from 'vue-router'
// 引入各个vue主键
import Map from '../map/MapperDemo'
import login from '../components/login'
import Main from '../components/Main'
import AccMangement from '../view/AccMangement'
import ReturnApproval from '../view/ReturnApproval'
import LossApplication from '../view/LossApplication'
import AddWarehouse from '../view/AddWarehouse'
import OperatonApplication from '../view/OperatonApplication'
import Logintest from '../view/Logintest'
import Rigter from '../view/Rigter'
import PictureDemo from '../view/PictureDemo'
import Hk from '../view/Hk'
import SupplierApplication from '../view/SupplierApplication'

import Vue from 'vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/Map',
    name: Map,
    component: Map},
  {
    path: '/',
    redirect: 'login'
  },
  {
    path: '/login',
    name: 'login',
    component: login
  },
  {
    path: '/Main',
    name: 'Main',
    component: Main
  },
  {
    path: '/addWarehouse',
    name: 'AddWarehouse',
    component: AddWarehouse
  },
  {
    path: '/AccMangemeent',
    name: 'AccMangemeent',
    component: AccMangement
  },
  {
    path: '/ReturnApproval',
    name: 'ReturnApproval',
    component: ReturnApproval
  },
  {
    path: '/LossApplication',
    name: 'LossApplication',
    component: LossApplication
  },
  {
    path: '/SupplierApplication',
    name: 'SupplierApplication',
    component: SupplierApplication
  },
  {
    path: '/OperatonApplication',
    name: 'OperatonApplication',
    component: OperatonApplication
  },
  {
    path: '/Logintest',
    name: 'Logintest',
    component: Logintest
  },
  {
    path: '/Rigter',
    name: 'Rigter',
    component: Rigter
  },
  {
    path: '/PictureDemo',
    name: 'PictureDemo',
    component: PictureDemo
  },
  {
    path: '/Hk',
    name: 'Hk',
    component: Hk
  }
]
export default new VueRouter({
  mode: 'history',
  routes
})
